<?php
global $NAMESPACE;
// ==== WSDL TYPES DECLARATION =================================================

// ---- int[] ------------------------------------------------------------------

$server->wsdl->addComplexType(
    'intArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'xsd:int[]')
    ),
    'xsd:int'
);

// ---- string[] ------------------------------------------------------------------

$server->wsdl->addComplexType(
    'stringArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'xsd:string[]')
    ),
    'xsd:string'
);


// ---- AssociativeArray -----------------------------------------------------------------

$server->wsdl->addComplexType(
    'Associative',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'key'            => array('name'=>'key',  'type'=>'xsd:string'),
        'value'          => array('name'=>'value','type'=>'xsd:string')
    )
);

// ---- AssociativeArray[] ---------------------------------------------------------------

$server->wsdl->addComplexType(
    'AssociativeArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Associative[]')),
    'tns:Associative'
);


// ---- Entity -----------------------------------------------------------------

$server->wsdl->addComplexType(
    'Entity',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'            => array('name'=>'id','type'=>'xsd:int'),
        'type'          => array('name'=>'type','type'=>'xsd:int'),
        'key'           => array('name'=>'key','type'=>'xsd:int')
    )
);

// ---- Entity[] ---------------------------------------------------------------

$server->wsdl->addComplexType(
    'EntityArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Entity[]')),
    'tns:Entity'
);


// ---- Group ------------------------------------------------------------------

$server->wsdl->addComplexType(
    'Group',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'type'        => array('name'=>'type','type'=>'xsd:int'),
        'metagroup'   => array('name'=>'metagroup','type'=>'xsd:int'),
        'entity'      => array('name'=>'entity','type'=>'tns:intArray')
    )
);

// ---- Group[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'GroupArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Group[]')
    ),
    'tns:Group'
);

// ---- Client -----------------------------------------------------------------

$server->wsdl->addComplexType(
    'Client',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'surname'     => array('name'=>'surname','type'=>'xsd:string'),
        'extension'   => array('name'=>'extension','type'=>'xsd:string'),
        'alias'       => array('name'=>'alias','type'=>'xsd:string'),
        'username'    => array('name'=>'username','type'=>'xsd:string'),
        'password'    => array('name'=>'password','type'=>'xsd:string'),
        'language'    => array('name'=>'language','type'=>'xsd:string'),
        'options'     => array('name'=>'options','type'=>'tns:AssociativeArray'),
        'groups'      => array('name'=>'groups','type'=>'tns:intArray'),
        'rule'        => array('name'=>'rule','type'=>'xsd:int'),
        'technology'  => array('name'=>'technology','type'=>'xsd:int'),
        'voicemail'   => array('name'=>'voicemail','type'=>'tns:VoiceMail')
    )
);

// ---- Client[] ---------------------------------------------------------------

$server->wsdl->addComplexType(
    'ClientArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Client[]')
    ),
    'tns:Client'
);

// ---- Office -------------------------------------------------------------

$server->wsdl->addComplexType(
    'Office',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'speeddial'   => array('name'=>'speeddial','type'=>'xsd:string'),
        'inkey'       => array('name'=>'inkey','type'=>'xsd:string'),
        'username'    => array('name'=>'username','type'=>'xsd:string'),
        'password'    => array('name'=>'password','type'=>'xsd:string'),
        'host'        => array('name'=>'host','type'=>'xsd:string'),
        'port'        => array('name'=>'port','type'=>'xsd:int'),
        'register'    => array('name'=>'register','type'=>'xsd:int'),
        'did'         => array('name'=>'did','type'=>'xsd:int'),
        'options'     => array('name'=>'options','type'=>'tns:AssociativeArray'),
        'numbers'     => array('name'=>'numbers','type'=>'tns:stringArray'),
        'groups'      => array('name'=>'groups','type'=>'tns:intArray'),
        'rule'        => array('name'=>'rule','type'=>'xsd:int')
    )
);

// ---- Office[] --------------------------------------------------------------

$server->wsdl->addComplexType(
    'OfficeArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Office[]')
    ),
    'tns:Office'
);

// ---- Provider ---------------------------------------------------------------

$server->wsdl->addComplexType(
    'Provider',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'speeddial'   => array('name'=>'speeddial','type'=>'xsd:string'),
        'username'    => array('name'=>'username','type'=>'xsd:string'),
        'password'    => array('name'=>'password','type'=>'xsd:string'),
        'host'        => array('name'=>'host','type'=>'xsd:string'),
        'port'        => array('name'=>'port','type'=>'xsd:string'),
        'did'         => array('name'=>'did','type'=>'xsd:string'),
        'numbers'     => array('name'=>'numbers','type'=>'tns:intArray'),
        'technology'  => array('name'=>'technology','type'=>'xsd:int'),
        'options'     => array('name'=>'options','type'=>'tns:AssociativeArray'),
        'groups'      => array('name'=>'groups','type'=>'tns:intArray'),
        'rule'        => array('name'=>'rule','type'=>'xsd:int')
    )
);

// ---- Provider[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'ProviderArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Provider[]')
    ),
    'tns:Provider'
);

// ---- Technology ---------------------------------------------------------------

$server->wsdl->addComplexType(
    'Technology',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'voip'        => array('name'=>'voip','type'=>'xsd:int'),
        'config_file' => array('name'=>'config_file','type'=>'xsd:string'),
        'realtime'    => array('name'=>'realtime','type'=>'xsd:int'),
        'table'       => array('name'=>'table','type'=>'xsd:string')
    )
);

// ---- Technology[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'TechnologyArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Technology[]')
    ),
    'tns:Technology'
);

// ---- PhoneNumber ------------------------------------------------------------

$server->wsdl->addComplexType(
    'PhoneNumber',
    'complexType',
    'struct',
    'all',
    '$NAMESPACE',
    array(
        'id'        => array('name'=>'id','type'=>'xsd:int'),
        'name'      => array('name'=>'name','type'=>'xsd:string'),
        'number'    => array('name'=>'number','type'=>'tns:stringArray'),
        'emergency' => array('name'=>'emergendy','type'=>'xsd:int'),
        'groups'    => array('name'=>'groups','type'=>'tns:intArray')
    )
);

// ---- PhoneNumber[] ----------------------------------------------------------

$server->wsdl->addComplexType(
    'PhoneNumberArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:PhoneNumber[]')),
    'tns:PhoneNumber'
);


// ---- Queue ------------------------------------------------------------------

$server->wsdl->addComplexType(
    'Queue',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'                  => array('name'=>'id','type'=>'xsd:int'),
        'name'                => array('name'=>'name','type'=>'xsd:string'),
        'strategy'            => array('name'=>'strategy','type'=>'xsd:string'),
        'music'               => array('name'=>'music','type'=>'xsd:string'),
        'announce-frequency'  => array('name'=>'announce-frequency','type'=>'xsd:int'),
        'announce-holdtime'   => array('name'=>'announce-holdtime','type'=>'xsd:string'),
        'joinempty'           => array('name'=>'joinempty','type'=>'xsd:string'),
        'member'              => array('name'=>'member','type'=>'tns:intArray')
    )
);

// ---- Queue[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'QueueArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Queue[]')
    ),
    'tns:Queue'
);

// ---- Ivr --------------------------------------------------------------------

$server->wsdl->addComplexType(
    'Ivr',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'                  => array('name'=>'id','type'=>'xsd:int'),
        'name'                => array('name'=>'name','type'=>'xsd:string'),
        'rootnode'            => array('name'=>'rootnode','type'=>'xsd:int')
    )
);

// ---- Ivr[] ------------------------------------------------------------------

$server->wsdl->addComplexType(
    'IvrArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Ivr[]')
    ),
    'tns:Ivr'
);


// ---- IvrNode ----------------------------------------------------------------

$server->wsdl->addComplexType(
    'IvrNode',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'parent'      => array('name'=>'parent','type'=>'xsd:int'),
        'order'       => array('name'=>'order','type'=>'xsd:int'),
        'key'         => array('name'=>'key','type'=>'xsd:string'),
        'audio'       => array('name'=>'audio','type'=>'xsd:string'),
        'macro'       => array('name'=>'macro','type'=>'xsd:int'),
        'parameter'   => array('name'=>'parameter','type'=>'xsd:string'),
        'timesegment' => array('name'=>'timesegment','type'=>'xsd:int'),
        'taudio'      => array('name'=>'taudio','type'=>'xsd:string'),
        'trepeat'     => array('name'=>'trepeat','type'=>'xsd:int'),
        'iaudio'      => array('name'=>'iaudio','type'=>'xsd:string'),
        'irepeat'     => array('name'=>'irepeat','type'=>'xsd:int')
    )
);

// ---- IvrNode[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'IvrNodeArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:IvrNode[]')
    ),
    'tns:IvrNode'
);



// ---- Option ------------------------------------------------------------------

$server->wsdl->addComplexType(
    'Option',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'                  => array('name'=>'id',       'type'=>'xsd:int'),
        'general_section'     => array('name'=>'general_section',     'type'=>'xsd:int'),
        'default_section'     => array('name'=>'default_section',     'type'=>'xsd:int'),
        'advanced_option'     => array('name'=>'advanced_option',     'type'=>'xsd:int'),
        'name'                => array('name'=>'name',     'type'=>'xsd:string'),
        'value'               => array('name'=>'value',    'type'=>'xsd:string'),
        'category'            => array('name'=>'category', 'type'=>'xsd:string'),
        'default'             => array('name'=>'default',  'type'=>'xsd:string'),
        'valuelist'           => array('name'=>'valuelist','type'=>'xsd:string'),
        'type'                => array('name'=>'type',     'type'=>'xsd:string'),
        'comment'             => array('name'=>'comment',  'type'=>'xsd:string'),
        'commented'           => array('name'=>'commented','type'=>'xsd:int')
    )
);

// ---- Option[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'OptionArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Option[]')
    ),
    'tns:Option'
);

// ---- ISDN Card --------------------------------------------------------------

$server->wsdl->addComplexType(
    'Card',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'                  => array('name'=>'id',      'type'=>'xsd:int'),
        'name'                => array('name'=>'name',    'type'=>'xsd:string'),
        'ports'                => array('name'=>'ports',    'type'=>'xsd:int'),
        'driver'                => array('name'=>'driver',    'type'=>'xsd:string')
    )
);

// ---- ISDN Card[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'CardArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Card[]')
    ),
    'tns:Card'
);

// ---- ISDN Port --------------------------------------------------------------

$server->wsdl->addComplexType(
    'Port',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'                  => array('name'=>'id',      'type'=>'xsd:int'),
        'port'                => array('name'=>'port',    'type'=>'xsd:int'),
        'layermask'           => array('name'=>'layermask','type'=>'xsd:string'),
        'protocol'            => array('name'=>'protocol',    'type'=>'xsd:string'),
        'card'                => array('name'=>'card',    'type'=>'xsd:int'),
        'card_id'             => array('name'=>'card',    'type'=>'xsd:int'),
        'available'           => array('name'=>'available','type'=>'xsd:int')
    )
);

// ---- ISDN Port[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'PortArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Port[]')
    ),
    'tns:Port'
);

// ---- ISDN Group --------------------------------------------------------------

$server->wsdl->addComplexType(
    'IsdnGroup',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'            => array('name'=>'id',          'type'=>'xsd:int'),
        'name'          => array('name'=>'name',        'type'=>'xsd:string'),
        'channel_order' => array('name'=>'channel_order', 'type'=>'xsd:int'),
        'msns'          => array('name'=>'msns',        'type'=>'tns:stringArray'),
        'port'          => array('name'=>'port',        'type'=>'tns:intArray'),
        //'rule'        => array('name'=>'rule',        'type'=>'xsd:int'),
        'speeddial'     => array('name'=>'speeddial',   'type'=>'xsd:string'),
        'port_type'     => array('name'=>'port_type',   'type'=>'xsd:string'),
        'did'           => array('name'=>'did',         'type'=>'xsd:int'),
        'option'        => array('name'=>'option',      'type'=>'tns:AssociativeArray')
    )
);

// ---- ISDN Group[] -------------------------------------------------------------

$server->wsdl->addComplexType(
    'IsdnGroupArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:IsdnGroup[]')
    ),
    'tns:IsdnGroup'
);

// ---- Action --------------------------------------------------------

$server->wsdl->addComplexType(
    'Action',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'       => array('name'=>'id',   'type'=>'xsd:int'),
        'name'     => array('name'=>'name','type'=>'xsd:string'),
        'fax'      => array('name'=>'fax',   'type'=>'xsd:int'),
        'app'      => array('name'=>'app','type'=>'tns:stringArray'),
        'appdata'  => array('name'=>'appdata','type'=>'tns:stringArray')
    )
);

// ---- Action[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'ActionArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Action[]')
    ),
    'tns:Action'
);

// ---- VoiceMail --------------------------------------------------------------

$server->wsdl->addComplexType(
    'VoiceMail',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'mailbox'     => array('name'=>'mailbox',     'type'=>'xsd:int'),
        'fullname'    => array('name'=>'fullname',    'type'=>'xsd:string'),
        'password'    => array('name'=>'password',    'type'=>'xsd:string'),
        'email'       => array('name'=>'email',       'type'=>'xsd:string'),
        'attach'      => array('name'=>'attach',      'type'=>'xsd:string'),
        'saycid'      => array('name'=>'saycid',      'type'=>'xsd:string'),
        'hidefromdir' => array('name'=>'hidefromdir', 'type'=>'xsd:string')
    )
);

// ---- VoiceMail[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'VoiceMailArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:VoiceMail[]')
    ),
    'tns:VoiceMail'
);

// ---- Directory --------------------------------------------------------------

$server->wsdl->addComplexType(
    'Directory',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'name'        => array('name'=>'name',     'type'=>'xsd:string'),
        'username'    => array('name'=>'username', 'type'=>'xsd:string'),
        'status'      => array('name'=>'status',   'type'=>'xsd:string')
    )
);

// ---- Directory[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'DirectoryArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Directory[]')
    ),
    'tns:Directory'
);

// ---- User --------------------------------------------------------------

$server->wsdl->addComplexType(
    'User',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'        => array('name'=>'id',       'type'=>'xsd:int'),
        'fullname'  => array('name'=>'fullname', 'type'=>'xsd:string'),
        'username'  => array('name'=>'username', 'type'=>'xsd:string'),
        'password'  => array('name'=>'password', 'type'=>'xsd:string'),
        'lang'      => array('name'=>'lang',     'type'=>'xsd:string'),
        'entity_id' => array('name'=>'entity_id','type'=>'xsd:int'),
        'exten'     => array('name'=>'exten',    'type'=>'xsd:string'),
        'technology'=> array('name'=>'technology','type'=>'xsd:int'),
        'type'      => array('name'=>'type',     'type'=>'xsd:int')
    )
);

// ---- User[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'UserArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:User[]')
    ),
    'tns:User'
);

// ---- CDR Request (call detail report)------------------------------------------------

$server->wsdl->addComplexType(
    'CdrRequest',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'source'  => array('name'=>'source', 'type'=>'xsd:string'),
        'type'  => array('name'=>'type', 'type'=>'xsd:string'),
        'search'  => array('name'=>'search', 'type'=>'xsd:string'),
        'from'  => array('name'=>'from', 'type'=>'xsd:string'),
        'to'  => array('name'=>'to', 'type'=>'xsd:string'),
        'orderBy'  => array('name'=>'orderBy', 'type'=>'xsd:string'),
        'page'  => array('name'=>'page', 'type'=>'xsd:int')
    )
);

// ---- CDR (call detail report)------------------------------------------------

$server->wsdl->addComplexType(
    'Cdr',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'entity'  => array('name'=>'entity', 'type'=>'xsd:string'),
        'received'  => array('name'=>'received', 'type'=>'xsd:string'),
        'dialed'  => array('name'=>'dialed', 'type'=>'xsd:string'),
        'channel'  => array('name'=>'channel', 'type'=>'xsd:string'),
        'calldate'  => array('name'=>'calldate', 'type'=>'xsd:string'),
        'duration'  => array('name'=>'duration', 'type'=>'xsd:string')
    )
);

// ---- CDR[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'CdrArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Crd[]')
    ),
    'tns:Cdr'
);

// ---- TimeSegment ------------------------------------------------------------

$server->wsdl->addComplexType(
    'TimeSegment',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'  => array('name'=>'id', 'type'=>'xsd:int'),
        'name'  => array('name'=>'name', 'type'=>'xsd:string'),
        'date_from'  => array('name'=>'date_from', 'type'=>'xsd:string'),
        'date_to'  => array('name'=>'date_to', 'type'=>'xsd:string'),
        'hour_from'  => array('name'=>'hour_from', 'type'=>'xsd:string'),
        'hour_to'  => array('name'=>'hour_to', 'type'=>'xsd:string'),
        'week_day'  => array('name'=>'week_day', 'type'=>'xsd:string'),
        'day'  => array('name'=>'day', 'type'=>'xsd:string'),
        'month'  => array('name'=>'month', 'type'=>'xsd:string')
    )
);

// ---- TimeSegment[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'TimeSegmentArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:TimeSegment[]')
    ),
    'tns:TimeSegment'
);


// ---- Rule -------------------------------------------------------------------

$server->wsdl->addComplexType(
    'Rule',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',          'type'=>'xsd:int'),
        'name'        => array('name'=>'name',        'type'=>'xsd:string'),
        'type'        => array('name'=>'type',        'type'=>'xsd:int'),
        'description' => array('name'=>'description', 'type'=>'xsd:string'),
        'outgoing'    => array('name'=>'outgoing',    'type'=>'tns:OutgoingRuleArray'),
        'incoming'    => array('name'=>'incoming',    'type'=>'tns:IncomingRuleArray')
    )
);

// ---- Rule[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'RuleArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Rule[]')
    ),
    'tns:Rule'
);

// ---- OutgoingRule ------------------------------------------------------------

$server->wsdl->addComplexType(
    'OutgoingRule',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',          'type'=>'xsd:int'),
        'rule'        => array('name'=>'rule',        'type'=>'xsd:int'),
        'priority'    => array('name'=>'priority',    'type'=>'xsd:int'),
        'timesegment' => array('name'=>'timesegment', 'type'=>'xsd:int'),
        'group'       => array('name'=>'group',       'type'=>'xsd:int'),
        'entity'      => array('name'=>'entity',      'type'=>'xsd:int'),
        'resource'    => array('name'=>'resource',    'type'=>'xsd:string'),
        'provider'    => array('name'=>'provider',    'type'=>'xsd:int'),
        'action'      => array('name'=>'action',      'type'=>'xsd:int')
    )
);

// ---- OutgoingRule[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'OutgoingRuleArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:OutgoingRule[]')
    ),
    'tns:OutgoingRule'
);

// ---- IncomingRule ------------------------------------------------------------

$server->wsdl->addComplexType(
    'IncomingRule',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',          'type'=>'xsd:int'),
        'rule'        => array('name'=>'rule',        'type'=>'xsd:int'),
        'priority'    => array('name'=>'priority',    'type'=>'xsd:int'),
        'timesegment' => array('name'=>'timesegment', 'type'=>'xsd:int'),
        'callertype'  => array('name'=>'callertype',    'type'=>'xsd:string'),
        'callerid'    => array('name'=>'callerid',    'type'=>'xsd:string'),
        'from_channel' => array('name'=>'from_channel',  'type'=>'xsd:int'),
        'from_number' => array('name'=>'from_number', 'type'=>'tns:stringArray'),
        'macro'       => array('name'=>'macro',       'type'=>'xsd:int'),
        'parameter'   => array('name'=>'parameter',   'type'=>'xsd:string'),
        'duration'    => array('name'=>'duration',    'type'=>'xsd:int')
    )
);

// ---- IncomingRule[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'IncomingRuleArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:IncomingRule[]')
    ),
    'tns:IncomingRule'
);



// ---- Macro ------------------------------------------------------------

$server->wsdl->addComplexType(
    'Macro',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'            => array('name'=>'id',          'type'=>'xsd:int'),
        'name'          => array('name'=>'name',       'type'=>'xsd:string'),
        'label'         => array('name'=>'label',       'type'=>'xsd:string'),
        'description'   => array('name'=>'description', 'type'=>'xsd:string'),
        'parameter'     => array('name'=>'parameter',   'type'=>'xsd:string'),
        'code'          => array('name'=>'code',        'type'=>'xsd:string')
    )
);

// ---- Macro[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'MacroArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Macro[]')
    ),
    'tns:Macro'
);

// ---- Application ------------------------------------------------------------

$server->wsdl->addComplexType(
    'Application',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id','type'=>'xsd:int'),
        'name'        => array('name'=>'name','type'=>'xsd:string'),
        'label'       => array('name'=>'label','type'=>'xsd:string'),
        'description' => array('name'=>'description','type'=>'xsd:string'),
        'extension'   => array('name'=>'extension','type'=>'xsd:string'),
        'code'        => array('name'=>'code','type'=>'xsd:string'),
        'macro'       => array('name'=>'macro','type'=>'xsd:int'),
        'parameter'   => array('name'=>'parameter','type'=>'xsd:string'),
        'groups'      => array('name'=>'groups','type'=>'tns:intArray')
    )
);

// ---- Application[] ----------------------------------------------------------

$server->wsdl->addComplexType(
    'ApplicationArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Application[]')
    ),
    'tns:Application'
);

// ---- Plugin ------------------------------------------------------------

$server->wsdl->addComplexType(
    'Plugin',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'             => array('name'=>'id','type'=>'xsd:int'),
        'label'          => array('name'=>'label','type'=>'xsd:string'),
        'name'           => array('name'=>'name','type'=>'xsd:string'),
        'package_name'   => array('package_name'=>'entity','type'=>'xsd:string'),
        'version'        => array('name'=>'version','type'=>'xsd:string'),
    )
);

// ---- Plugin[] ----------------------------------------------------------

$server->wsdl->addComplexType(
    'PluginArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Plugin[]')
    ),
    'tns:Plugin'
);

// ---- PluginEntity ------------------------------------------------------------

$server->wsdl->addComplexType(
    'PluginEntity',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'plugin_id'        => array('name'=>'plugin_id','type'=>'xsd:int'),
        'entity_type'      => array('name'=>'entity_type','type'=>'xsd:string'),
        'entity_id'        => array('name'=>'entity_id','type'=>'xsd:int'),
        'entity_version'   => array('name'=>'entity_version','type'=>'xsd:string'),
        
    )
);

// ---- PluginEntity[] ----------------------------------------------------------

$server->wsdl->addComplexType(
    'PluginEntityArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:PluginEntity[]')
    ),
    'tns:PluginEntity'
);

// ---- Channel ------------------------------------------------------------

$server->wsdl->addComplexType(
    'Channel',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',        'type'=>'xsd:int'),
        'name'        => array('name'=>'name',      'type'=>'xsd:string'),
        'technology'  => array('name'=>'technology','type'=>'xsd:int'), 
        'resource'    => array('name'=>'resource',  'type'=>'xsd:string'), 
        'key'         => array('name'=>'key',       'type'=>'xsd:int'), 
        'msns'        => array('name'=>'msns',      'type'=>'tns:stringArray'),
        'did'         => array('name'=>'did',       'type'=>'xsd:int'),
        'rule'        => array('name'=>'rule',      'type'=>'xsd:int'),
        'speeddial'   => array('name'=>'speeddial', 'type'=>'xsd:string'),
        'order'       => array('name'=>'order',     'type'=>'xsd:int'),
        'trunk'       => array('name'=>'trunk',     'type'=>'xsd:int')
    )
);

// ---- Channel[] ----------------------------------------------------------

$server->wsdl->addComplexType(
    'ChannelArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Channel[]')
    ),
    'tns:Channel'
);

// ---- AudioFile ------------------------------------------------------------

$server->wsdl->addComplexType(
    'AudioFile',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',        'type'=>'xsd:int'),
        'name'        => array('name'=>'name',      'type'=>'xsd:string'),
        'filename'    => array('name'=>'filename',  'type'=>'xsd:string'), 
        'date'        => array('name'=>'date',      'type'=>'xsd:string') 
    )
);

// ---- AudioFile[] ----------------------------------------------------------

$server->wsdl->addComplexType(
    'AudioFileArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:AudioFile[]')
    ),
    'tns:AudioFile'
);

// ---- VoiceMailStructure -----------------------------------------------------------------

$server->wsdl->addComplexType(
    'VoiceMailStructure',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'callerid'          => array('name'=>'callerid','type'=>'xsd:string'),
        'origdate'          => array('name'=>'origdate','type'=>'xsd:string'),
        'duration'          => array('name'=>'duration','type'=>'xsd:string'),
        'filename'          => array('name'=>'filename','type'=>'xsd:string')
    )
);

// ---- VoiceMailStructure[] ---------------------------------------------------------------

$server->wsdl->addComplexType(
    'VoiceMailStructureArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:VoiceMailStructure[]')),
    'tns:VoiceMailStructure'
);

// ---- AnswerMessageStructure -------------------------------------------------

$server->wsdl->addComplexType(
    'AnswerMessageStructure',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'filename'    => array('name'=>'filename',    'type'=>'xsd:string'),
        'md5'         => array('name'=>'md5',         'type'=>'xsd:string')
    )
);

// ---- AnswerMessageStructure[] -----------------------------------------------

$server->wsdl->addComplexType(
    'AnswerMessageStructureArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:AnswerMessageStructure[]')
    ),
    'tns:AnswerMessageStructure'
);

// ---- MohClassStructure ----------------------------------------------------
/*
$server->wsdl->addComplexType(
    'MohClassStructure',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',            'type'=>'xsd:int'),
        'name'        => array('name'=>'name',          'type'=>'xsd:string'),
        'mode'        => array('name'=>'mode',          'type'=>'xsd:string'),
        'dir'         => array('name'=>'dir',           'type'=>'xsd:string'),
        'application' => array('name'=>'application',   'type'=>'xsd:string')
    )
);
*/
$server->wsdl->addComplexType(
    'MohClassStructure',
    'complexType',
    'struct',
    'all',
    '',
    array(
       'name'        => array('name'=>'name',          'type'=>'xsd:string'),
       'mode'        => array('name'=>'mode',          'type'=>'xsd:string'),
       'application' => array('name'=>'application',   'type'=>'xsd:string')
    )
);
// ---- MohClassStructure[] --------------------------------------------------

$server->wsdl->addComplexType(
    'MohClassStructureArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:MohClassStructure[]')
    ),
    'tns:MohClassStructure'
);

// ---- MohClassDefinition ----------------------------------------------------

$server->wsdl->addComplexType(
    'MohClassDefinition',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'name'        => array('name'=>'name',          'type'=>'xsd:int'),
        'mode'        => array('name'=>'mode',          'type'=>'xsd:int'),
        'application' => array('name'=>'application',   'type'=>'xsd:string'),
        'songs'       => array('name'=>'songs',         'type'=>'tns:stringArray')
    )
);

// ---- MohClassDefinition[] --------------------------------------------------

$server->wsdl->addComplexType(
    'MohClassDefinitionArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:MohClassDefinition[]')
    ),
    'tns:MohClassDefinition'
);

// ---- soundsFile ----------------------------------------------------

$server->wsdl->addComplexType(
    'soundsFile',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',            'type'=>'xsd:int'),
        'name'        => array('name'=>'name',          'type'=>'xsd:string'),
        'cat_id'      => array('name'=>'cat_id',        'type'=>'xsd:int'),
        'cat_tag'     => array('name'=>'cat_tag',       'type'=>'xsd:string'),
        'category'    => array('name'=>'category',      'type'=>'xsd:string'),
        'filepath'    => array('name'=>'filepath',      'type'=>'xsd:string'),
        'text'        => array('name'=>'text',          'type'=>'xsd:string'),
        'lastmodified'=> array('name'=>'lastmodified',  'type'=>'xsd:string')
    )
);

// ---- soundsFile[] --------------------------------------------------

$server->wsdl->addComplexType(
    'soundsFileArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:soundsFile[]')
    ),
    'tns:soundsFile'
);

// ---- soundsCategories ----------------------------------------------------

$server->wsdl->addComplexType(
    'soundsCategories',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',           'type'=>'xsd:int'),
        'tag'         => array('name'=>'tag',          'type'=>'xsd:string'),
        'description' => array('name'=>'description',  'type'=>'xsd:string') 
    )
);

// ---- soundsCategories[] --------------------------------------------------

$server->wsdl->addComplexType(
    'soundsCategoriesArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:soundsCategories[]')
    ),
    'tns:soundsCategories'
);
// ---- commandReturn ----------------------------------------------------

$server->wsdl->addComplexType(
    'commandReturn',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'present'       => array('name'=>'present',        'type'=>'xsd:int'),
        'value'         => array('name'=>'value',          'type'=>'xsd:string')
    )
);

// ---- commandReturn[] --------------------------------------------------

$server->wsdl->addComplexType(
    'commandReturnArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:commandReturn[]')
    ),
    'tns:commandReturn'
);

// ---- Extension --------------------------------------------------------------

$server->wsdl->addComplexType(
    'Extension',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',        'type'=>'xsd:int'),
        'entity_id'   => array('name'=>'entity_id', 'type'=>'xsd:int'),
        'extension'   => array('name'=>'extension', 'type'=>'xsd:string'),
        'type'        => array('name'=>'type',      'type'=>'xsd:int')
    )
);

// ---- Extension[] ------------------------------------------------------------

$server->wsdl->addComplexType(
    'ExtensionArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Extension[]')
    ),
    'tns:Extension'
);


// ****************************************************************************
// ---- NEW ZAPATA PART STARTS HERE -------------------------------------------
// ****************************************************************************

// ---- Zapata Card -----------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapCard',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'             => array('name'=>'id',      'type'=>'xsd:int'),
        'name'           => array('name'=>'name',    'type'=>'xsd:string'),
        'ports'          => array('name'=>'ports',   'type'=>'xsd:int'),
        'type'           => array('name'=>'type',    'type'=>'xsd:string'),
        'span'           => array('name'=>'span',    'type'=>'xsd:int'),
        'order'          => array('name'=>'order',   'type'=>'xsd:int'),
        'driver'         => array('name'=>'driver',  'type'=>'xsd:string'),
        'active'         => array('name'=>'active',  'type'=>'xsd:int')
    )
);

// ---- Zapata Card[] ---------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapCardArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:ZapCard[]')
    ),
    'tns:ZapCard'
);

// ---- Zapata Port Option ----------------------------------------------------

$server->wsdl->addComplexType(
    'ZapPortOption',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'             => array('name'=>'id',       'type'=>'xsd:int'),
        'type'           => array('name'=>'type',     'type'=>'xsd:string'),
        'device'         => array('name'=>'device',   'type'=>'xsd:string'),
        'timing'         => array('name'=>'timing',   'type'=>'xsd:string'),
        'lbo'            => array('name'=>'lbo',      'type'=>'xsd:string'),
        'framing'        => array('name'=>'framing',  'type'=>'xsd:string'),
        'coding'         => array('name'=>'coding',   'type'=>'xsd:string'),
        'crc4'           => array('name'=>'crc4',     'type'=>'xsd:string'),
        'yellow'         => array('name'=>'yellow',   'type'=>'xsd:string')
    )
);

// ---- Zapata Port Option[] --------------------------------------------------

$server->wsdl->addComplexType(
    'ZapPortOptionArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:ZapPortOption[]')
    ),
    'tns:ZapPortOption'
);

// ---- Zapata Port -----------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapPort',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'             => array('name'=>'id',       'type'=>'xsd:int'),
        'port'           => array('name'=>'port',     'type'=>'xsd:int'),
        'type'           => array('name'=>'type',     'type'=>'xsd:string'),
        'device'         => array('name'=>'device',   'type'=>'xsd:string'),
        'span'           => array('name'=>'span',     'type'=>'xsd:int'),
        'timing'         => array('name'=>'timing',   'type'=>'xsd:int'),
        'lbo'            => array('name'=>'lbo',      'type'=>'xsd:int'),
        'framing'        => array('name'=>'framing',  'type'=>'xsd:string'),
        'coding'         => array('name'=>'coding',   'type'=>'xsd:string'),
        'crc4'           => array('name'=>'crc4',     'type'=>'xsd:int'),
        'yellow'         => array('name'=>'yellow',   'type'=>'xsd:int'),
        'order'          => array('name'=>'order',    'type'=>'xsd:int'),
        'card'           => array('name'=>'card',     'type'=>'xsd:int'),
        'card_id'        => array('name'=>'card_id',  'type'=>'xsd:int')
    )
);

// ---- Zapata Port[] ---------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapPortArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:ZapPort[]')
    ),
    'tns:ZapPort'
);

// ---- Zapata Channel --------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapChannel',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'             => array('name'=>'id',        'type'=>'xsd:int'),
        'port_id'        => array('name'=>'port_id',   'type'=>'xsd:int'),
        'order'          => array('name'=>'order',     'type'=>'xsd:int'),
        'group'          => array('name'=>'group',     'type'=>'xsd:string'),
        'type'           => array('name'=>'type',      'type'=>'xsd:string'),
        'device'         => array('name'=>'device',    'type'=>'xsd:string'),
        'signalling'     => array('name'=>'signalling','type'=>'xsd:string'),
        'pchannel'       => array('name'=>'pchannel',  'type'=>'xsd:int'),
        'zchannel'       => array('name'=>'zchannel',  'type'=>'xsd:int'),
        'available'      => array('name'=>'available', 'type'=>'xsd:int')
    )
);

// ---- Zapata Channel[] ------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapChannelArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:ZapChannel[]')
    ),
    'tns:ZapChannel'
);

// ---- Zapata Group ----------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapGroup',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'            => array('name'=>'id',            'type'=>'xsd:int'),
        'group'         => array('name'=>'group',         'type'=>'xsd:int'),
        'name'          => array('name'=>'name',          'type'=>'xsd:string'),
        'rule'          => array('name'=>'rule',          'type'=>'xsd:int'),
        'msns'          => array('name'=>'msns',          'type'=>'tns:stringArray'),
        'type'          => array('name'=>'type',          'type'=>'xsd:string'),
        'did'           => array('name'=>'did',           'type'=>'xsd:int'),
        'signalling'    => array('name'=>'signalling',    'type'=>'xsd:string'),
        'speeddial'     => array('name'=>'speeddial',     'type'=>'xsd:string'),
        'channel_order' => array('name'=>'channel_order', 'type'=>'xsd:int'),
        'port'          => array('name'=>'port',          'type'=>'tns:intArray'),
        'option'        => array('name'=>'option',        'type'=>'tns:AssociativeArray')
    )
);

// ---- Zapata Group[] --------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapGroupArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:ZapGroup[]')
    ),
    'tns:ZapGroup'
);

// ---- Zapata Tonezone -------------------------------------------------------

$server->wsdl->addComplexType(
    'ZapToneZone',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'             => array('name'=>'id',          'type'=>'xsd:int'),
        'name'           => array('name'=>'name',        'type'=>'xsd:string'),
        'fullname'       => array('name'=>'fullname',    'type'=>'xsd:string'),
        'loadzone'       => array('name'=>'loadzone',    'type'=>'xsd:int'),
        'defaultzone'    => array('name'=>'defaultzone', 'type'=>'xsd:int')
    )
);

// ---- Zapata Tonezone[] -----------------------------------------------------

$server->wsdl->addComplexType(
    'ZapToneZoneArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:ZapToneZone[]')
    ),
    'tns:ZapTone'
);

// ****************************************************************************
// ---- NEW ZAPATA PART ENDS HERE ---------------------------------------------
// ****************************************************************************

// ---- Meetme -----------------------------------------------------------------

$server->wsdl->addComplexType(
    'Meetme',
    'complexType',
    'struct',
    'all',
    '',
    array(
        'id'          => array('name'=>'id',          'type'=>'xsd:int'),
        'confno'      => array('name'=>'confno',      'type'=>'xsd:string'),
        'pin'         => array('name'=>'pin',         'type'=>'xsd:string'),
        'adminpin'    => array('name'=>'adminpin',    'type'=>'xsd:string'),
        'app_id'      => array('name'=>'app_id',      'type'=>'xsd:int'),
        'app_name'    => array('name'=>'app_name',    'type'=>'xsd:string'),
        'application' => array('name'=>'application', 'type'=>'tns:Application')
    )
);

// ---- Meetme[] ------------------------------------------------------------

$server->wsdl->addComplexType(
    'MeetmeArray',
    'complexType',
    'array',
    '',
    'SOAP-ENC:Array',
    array(),
    array(
        array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'tns:Meetme[]')
    ),
    'tns:Meetme'
);

?>
